<?php

//基本栏目控制器
class About extends Controller {

	var $userid;
	
	function About()
	{
		parent::Controller();	
		$this->load->model("accounts_model", "am");
		$this->load->model("about_model");
		//登陆状态检测
		$this->userid = $this->am->is_logined();
		$this->account = $this->am->get_account();
	}
	
	//默认首页
	function index()
	{
		//输出公共header
		$pagedata["topmenuid"] = 4;
		$page = u(2);
		switch ($page) {
			case "contact":
				$viewdata["title"] = "联系我们";
			break;
			case "ad":
				$viewdata["title"] = "违规举报";
			break;
			case "hr":
				$viewdata["title"] = "职位招聘";
			break;
			case "partner":
				$viewdata["title"] = "合作伙伴";
			break;
			case "sitemap":
				$viewdata["title"] = "网站地图";
			break;
			case "help":
				$viewdata["title"] = "帮助中心";
			break;
			case "legal":
				$viewdata["title"] = "法律声明";
			break;
			default:
				$viewdata["title"] = "关于我们";
		}
		if(!isset($pagedata["title"])) $pagedata["title"] = $viewdata["title"]." | 热闹网";
		if(!isset($pagedata["keywords"])) $pagedata["keywords"] = "热闹、热闹网、热闹100、renao、renao100、轻网站、网站、小站、微网站、博客、社区、互动";
		if(!isset($pagedata["description"])) $pagedata["description"] = "热闹网(www.renao100.com) - 前所未有的互动轻网站社区。轻网站是一个创意点子的实现，每个人拥有属于自己的轻网站，并且允许共同维基创建内容。适合个人站、兴趣站、才艺站、组织站甚至官方站。轻网站可以是WEB1.0，更可以是WEB2.0。";
		$this->autoload_model->output_header($pagedata);

		$row = $this->about_model->get($page);
		$viewdata["row"] = $row;
		$this->load->view(__CLASS__.'/index', $viewdata);
		
		//输出公共footer
		$this->autoload_model->output_footer();
	}
}

/* End of file */